﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Threading;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace WebApplication1
{
    public partial class Sample : System.Web.UI.Page
    {
        protected override void InitializeCulture()
        {
            string language = "French";
            string languageId = "";

            if (!string.IsNullOrEmpty(language))
            {
                if (language.EndsWith("French"))
                    languageId = "fr-FR";
                else languageId = "en-US";
                Thread.CurrentThread.CurrentCulture =
                CultureInfo.CreateSpecificCulture(languageId);

                Thread.CurrentThread.CurrentUICulture = new CultureInfo(languageId);
            }
            base.InitializeCulture();
        }

        protected void Page_Load(object sender, EventArgs e)
        {
            Label3.Text = Resources.LocalizedText.Msg1;

        }
    }
}